package com.fisherman.bean;

import org.springframework.beans.factory.DisposableBean;
import org.springframework.beans.factory.InitializingBean;
import org.springframework.stereotype.Component;

/**
 * @User: fisherman
 * @Date: 2020/5/21 8:55
 */
@Component
public class Cat implements InitializingBean, DisposableBean {
    public Cat(){
        System.out.println("cart  constructor....");
    }

    //销毁方法
    public void destroy() throws Exception {

        System.out.println("cat....destroy");
    }

    //初始化方法
    public void afterPropertiesSet() throws Exception {

        System.out.println("cat...afterPropertiesSet");
    }
}
